Getting Started
Unzip the downloaded ZIP file for this tutorial to the ColdFusion MX webroot. The download ZIP extracts to a folder named devnet in your webroot (such as http://localhost:8500/devnet/). The ZIP file contains a database, ColdFusion component, and some FLA files. The following sections presume that you have installed these files at http://localhost:8500/devnet, or within your ColdFusion MX webroot, in a directory called devnet. This tutorial also assumes you are using the ColdFusion MX built-in web server, listening at port 8500.
Open and examine the Macromedia Flash source files. Open devnet_begin1.fla, which contains the Macromedia Flash Stage elements. Notice that the ComboBox is on a separate layer called Types ComboBox. This is because the ComboBox and a TextBox occupy the same location but become visible at different times. Hide the Types ComboBox layer and you will see the TextBox used to display part types.
If you look at the Actions panel, you will notice that a number of comments separate the page into sections. This is one possible way to organize your ActionScript code. ActionScript coders have developed their own ways to organize code; this method could be a good starting point for you.
The ZIP file also includes prebuilt optional starting points for all five of the exercises. So, for instance, you can use the file devnet_begin3.fla when you begin Exercise 3 to ensure you have the correct code. You do not have to use these files. They are provided for reference and give you a solid beginning point for each exercise if you choose to use them. The ZIP file also contains the complete application, named devnet_finished_solution.fla.
Configure your data source. Configure the database in the ZIP as a data source. The database file is called bikeparts.mdb. Configure it as a data source named bikeparts in the ColdFusion Administrator. Use the following steps if you're unsure:
- Open ColdFusion Administrator (Start > Programs > Macromedia ColdFusion MX > Administrator) and enter the administrator password, if needed. Consult the system administrator of your server for assistance if you do not have access to ColdFusion Administrator.
- Click the Data Sources link under the Data & Services heading in the ColdFusion Administrator left navigation bar.
- Within the Data Sources module of ColdFusion Administrator, enter bikeparts in the Data Source Name field.
- From the Driver pop-up menu, choose Microsoft Access.
- Click Add. This takes you to the detail screen for the Microsoft Access data source.
- Click Browse Server to the right of the Database File field. The Browse Server dialog box will appear.
- Browse to the location C:\CFusionMX\wwwroot\devnet and select bikeparts.mdb. Click Apply.
- Click Submit to create the data source.
- ColdFusion Administrator takes you back to the Data Sources screen, where the text OK appears in the status field for the bikeparts data source you just created.
Submit feedback on our tutorials, articles, and sample applications.